<?php
use lib\controller\Controller;
use lib\dao\query\Query;

class UserController extends Controller{
	
	public function index(){
		try{
			//$this->View->debug();
			$this->getMessages();
		
			//creo un modelo de categoria
                        $Q = new Query($this->Model);
			$this->View->assign('user',$this->Model->fetch($Q));
                        
			//Muestro template
			$this->View->display();
		}
		catch (\Exception $e){
			die($e->getMessage());
		}	
	}
	
}